/*
 * @Author: boyyang
 * @Date: 2022-01-02 18:21:16
 * @LastEditTime: 2022-01-02 22:20:02
 * @LastEditors: boyyang
 * @Description: 初始化cloudbase 环境
 * @FilePath: \boyyang\src\cloudbase\init.ts
 */

import cloudbase from '@cloudbase/js-sdk'
import { env } from '@/utils/env'

const app = cloudbase.init({
    env: env.VITE_APP_CLOUDKEY,
    persistence: 'local'
})

const auth = app.auth({
    persistence: 'local'
})

const db = app.database()

export {
    app,
    auth,
    db
}
